
package com.agp;

import lombok.extern.slf4j.Slf4j;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Bean;
import org.springframework.web.client.RestTemplate;

@SpringBootApplication
@EnableDiscoveryClient
@MapperScan("com.agp.mapper")
@Slf4j
public class ShardingApplication {

    public static void main(String[] args)  {
        SpringApplication.run(ShardingApplication.class, args);
        log.info("spring-cloud-eureka-consumer启动!");
    }

    @Bean
    public RestTemplate restTemplate() {
        return new RestTemplate();
    }
}